package com.dragon.mmochat.message;

import com.dragon.mmochat.MmochatConstant;
import com.skymobi.buffer.SkymobiBuffer;
import com.skymobi.message.SkymobiProtocolMessage;

public class Mmochat_10_4S extends SkymobiProtocolMessage {
	private int sendRoleId; // 消息发送者的roleId
	private String title;
	private String msg;

	public Mmochat_10_4S() {
		setMsgCode(MmochatConstant.MSGCODE_MMOCHAT_S_10_4);
	}

	@Override
	protected void encodeBody(SkymobiBuffer out) {
		out.putInt(sendRoleId);
		out.putPrefixedString(title, 2);
		out.putPrefixedString(msg, 2);
	}

	public void setSendRoleId(int sendRoleId) {
		this.sendRoleId = sendRoleId;
	}

	public void setTitle(String title) {
		this.title = title;
	}

	public void setMsg(String msg) {
		this.msg = msg;
	}

}
